package com.cl.mapper;

import com.cl.pojo.User;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface UserMapper{
    /**
     * 查询全部用户
     * @return
     */
    List<User> queryAll();
    /**
     * 插入一个用户  注册功能
     * @param user
     * @return
     */
    int insertUser(User user);

    /**
     * 根据邮箱查询用户
     * @param email
     * @return
     */
    User queryByEmail(@Param("email") String email);

    /**
     *
     * @param lid
     * @param password
     * @return
     */
    int updatePwd(@Param("lid")int lid,@Param("password")String password);
}
